/*
 * @Author: your name
 * @Date: 2022-03-23 20:41:42
 * @LastEditTime: 2022-03-23 21:00:44
 * @LastEditors: your name
 * @Description: 打开koroFileHeader查看配置 进行设置: https://github.com/OBKoro1/koro1FileHeader/wiki/%E9%85%8D%E7%BD%AE
 * @FilePath: \gtest_demo\gtest_demo.cpp
 */
#include<gtest/gtest.h>
#include "function/cpu_usage.h"
#include <Windows.h>

int add(int a,int b){
    return a+b;
}

TEST(testCase,test0){
    EXPECT_EQ(add(2,3),5);
}

TEST(testCase,test1){
  CProcessMonitor ussage1(21132);
  while (1)
  {
    std::cout<<ussage1.GetCpuUsage()<<std::endl;
    Sleep(1000);
  }
}
int main(int argc,char **argv){
  testing::InitGoogleTest(&argc,argv);
  return RUN_ALL_TESTS();
}



